package com.chaoxuan.uebt.adapter;

import android.view.View;
import android.widget.ImageView;

import com.bumptech.glide.Glide;
import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.chaoxuan.uebt.R;
import com.chaoxuan.uebt.model.Ad;

/**
 * Created by Administrator on 2019/5/24.
 */
public class OnlineAdapter extends BaseQuickAdapter<Integer,BaseViewHolder>{

    public OnlineAdapter() {
        super(R.layout.fragment_index_item);
    }

    @Override
    protected void convert(BaseViewHolder helper,Integer item) {
        helper.getView(R.id.img_online1).setVisibility((item==1)?View.VISIBLE:View.GONE);
        helper.getView(R.id.img_online2).setVisibility((item==0)?View.VISIBLE:View.GONE);
    }
}
